<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class ChangePropsValTableToInnodb extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::dropIfExists('props_vals');
        Schema::create('props_vals', function (Blueprint $table) {
            $table->engine='innoDb';
            $table->increments('props_val_id');
            $table->string('name')->comment('属性的值的名称');
            $table->integer('props_id')->comment('props表的外键');
            $table->integer('sort')->comment('排序的序号')->default(0);
            $table->tinyInteger('disabled')->comment('是否删除 0-否 1-是')->default(0);
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        //
    }
}
